package com.ruoyi.ring.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.ring.mapper.RingTrainingInfoMapper;
import com.ruoyi.ring.domain.RingTrainingInfo;
import com.ruoyi.ring.service.IRingTrainingInfoService;

/**
 * 训练详细Service业务层处理
 * 
 * @author liuwp
 * @date 2025-08-18
 */
@Service
public class RingTrainingInfoServiceImpl implements IRingTrainingInfoService 
{
    @Autowired
    private RingTrainingInfoMapper ringTrainingInfoMapper;

    /**
     * 查询训练详细
     * 
     * @param id 训练详细主键
     * @return 训练详细
     */
    @Override
    public RingTrainingInfo selectRingTrainingInfoById(Long id)
    {
        return ringTrainingInfoMapper.selectRingTrainingInfoById(id);
    }

    /**
     * 查询训练详细列表
     * 
     * @param ringTrainingInfo 训练详细
     * @return 训练详细
     */
    @Override
    public List<RingTrainingInfo> selectRingTrainingInfoList(RingTrainingInfo ringTrainingInfo)
    {
        return ringTrainingInfoMapper.selectRingTrainingInfoList(ringTrainingInfo);
    }

    /**
     * 根据业务主键查询一条记录：训练详细
     *
     * @param ringTrainingInfo 训练详细
     * @return 训练详细
     */
    @Override
    public RingTrainingInfo selectOneRingTrainingInfo(RingTrainingInfo ringTrainingInfo)
    {
        return ringTrainingInfoMapper.selectOneRingTrainingInfo(ringTrainingInfo);
    }

    /**
     * 新增训练详细
     * 
     * @param ringTrainingInfo 训练详细
     * @return 结果
     */
    @Override
    public int insertRingTrainingInfo(RingTrainingInfo ringTrainingInfo)
    {
        return ringTrainingInfoMapper.insertRingTrainingInfo(ringTrainingInfo);
    }

    /**
     * 修改训练详细
     * 
     * @param ringTrainingInfo 训练详细
     * @return 结果
     */
    @Override
    public int updateRingTrainingInfo(RingTrainingInfo ringTrainingInfo)
    {
        return ringTrainingInfoMapper.updateRingTrainingInfo(ringTrainingInfo);
    }

    @Override
    public int updateRingTrainingInfoCondition(RingTrainingInfo ringTrainingInfo, RingTrainingInfo ringTrainingInfoCondition)
    {
        return ringTrainingInfoMapper.updateRingTrainingInfoCondition(ringTrainingInfo, ringTrainingInfoCondition);
    }

    /**
     * 批量删除训练详细
     * 
     * @param ids 需要删除的训练详细主键
     * @return 结果
     */
    @Override
    public int deleteRingTrainingInfoByIds(Long[] ids)
    {
        return ringTrainingInfoMapper.deleteRingTrainingInfoByIds(ids);
    }

    /**
     * 删除训练详细信息
     * 
     * @param id 训练详细主键
     * @return 结果
     */
    @Override
    public int deleteRingTrainingInfoById(Long id)
    {
        return ringTrainingInfoMapper.deleteRingTrainingInfoById(id);
    }

    /**
     * 条件删除训练详细
     *
     * @param ringTrainingInfo 训练详细
     * @return 结果
     */
    @Override
    public int deleteRingTrainingInfoByCondition(RingTrainingInfo ringTrainingInfo)
    {
        return ringTrainingInfoMapper.deleteRingTrainingInfoByCondition(ringTrainingInfo);
    }

}
